<!DOCTYPE html>
<html lang="en">
    <head>
        <meta charset="utf-8">
        <meta name="viewport" content="width=device-width,minimum-scale=1,maximum-scale=1" >



    </head>
    <script type="text/javascript" src="../js/lib/jquery.js"></script>
    <link rel="stylesheet" href="../css/H5ComponentBase.css">
    <script type="text/javascript" src="../js/H5ComponentBase.js"></script>
    <link rel="stylesheet" href="../css/H5ComponentPoint.css">
    <script type="text/javascript" src="../js/H5ComponentPoint.js"></script>
    <body>
      <div class="iphone"></div>
      <script>
        var cfg = {
          type:'point',

          width:300,
          height:300,
          data:[
            ['A项',.4,'green'],
            ['B项',.2,'yellow',0,'-60%'],
            ['c项',.1,'red',0,'120%']
          ],
          css:{
            bottom:0,
            opacity:1
          },
          animateIn:{bottom:'40%',opacity:1},
          animateOut:{bottom:0,opacity:0},
          center:true
        }
        var base = new H5ComponentPoint('myName',cfg);
        $('.iphone').append(base);

        var leave = true;
        $('body').click(function(){
          leave=!leave;
          $('.h5_component_point').trigger(leave? "onLeave":"onLoad")
        });
      </script>
    </body>
</html>